import request from '@/utils/request'

// 查询分类列表
export function listCategory1(query) {
  return request({
    url: '/tcm/category1/list',
    method: 'get',
    params: query
  })
}

// 查询分类详细
export function getCategory1(id) {
  return request({
    url: '/tcm/category1/' + id,
    method: 'get'
  })
}

// 新增分类
export function addCategory1(data) {
  return request({
    url: '/tcm/category1',
    method: 'post',
    data: data
  })
}

// 修改分类
export function updateCategory1(data) {
  return request({
    url: '/tcm/category1',
    method: 'put',
    data: data
  })
}

// 删除分类
export function delCategory1(id) {
  return request({
    url: '/tcm/category1/' + id,
    method: 'delete'
  })
}
